cmake_minimum_required(VERSION 3.0)  
  
project(jumpGame)  
  
set(CMAKE_BUILD_TYPE "Debug")  
  
# 设置源文件目录  
set(SOURCE_DIR "./src")  
  
# 使用file(GLOB ...)命令收集所有.cpp文件  
file(GLOB SOURCES "${SOURCE_DIR}/*.cpp")  
  
  
# 设置头文件目录  
set(INCLUDE_DIR "./include")  
  
# 使用include_directories()来指定头文件的搜索路径  
include_directories(${INCLUDE_DIR})  

   
# 添加可执行文件，并链接SDL2库  
link_libraries(SDL2 SDL2_image SDL2_ttf)
add_executable(main_cmake ${SOURCES})  

